<table cellspacing="0" cellpadding="0" align="center" width="100%">
    <?php foreach ($view->newcomments as $k => $comments) { ?>
    <?php if($k == 0) {?>
    <tr>
        <td width="25%" height="30">
        </td>
        <td width="25%" height="30">
        </td>
        <td colspan="2" width="25%" height="30" align="right">
            
            Sorter etter: 
            | <a href="?action=vote&order=total_like&sort=desc">Populære</a> | 
            <a href="?action=vote&order=created_time&sort=desc">Nyeste</a> | 
            <a href="?action=vote&order=created_time&sort=asc">Eldste</a>
            
        </td>
    </tr>
    <?php } ?>
    <tr>
        <?php foreach ($comments as $c) { ?>
            <td valign="top" align="center" width="25%">
                <div class="b1px po">
                    <!--
                    <div class="bg_vote" id="home-total-like-<?php echo $c['data_id']; ?>"><?php echo $c['total_like']; ?></div>
                    -->
                    <a href="//javascript:facebooktab.showLikeLightbox(<?php echo $c['data_id']; ?>);">
                        <div style="height: 140px; width: 173px; overflow: hidden;">
                            <img style="width: 173px;height: auto;" src="http://graph.facebook.com/<?php echo $c['facebook_user_id'];?>/picture/?type=large" alt="" />
                        </div>                        
                    </a>
                    <div class="green_bg">
                        <?php echo substr($c['name'], 0, 22); ?><?php if (strlen($c['name']) > 15) { echo "...";} ?>
                    </div>
                </div>
                <!--
                <div class="bg_btn <?php if ($view->isLogined && ($c['is_liked'] > 0)) { ?>btn_liked<?php } ?>" id="like-area-<?php echo $c['data_id']; ?>">
                    
                    <?php if(!$view->isEndOfContest) { ?>
                        <?php if ($view->isLogined && ($c['is_liked'] > 0)) { ?>
                                    <a href="javascript:contestapp.unlikecomment(<?php echo $c['data_id']; ?>)">
                                        STEM
                                    </a>
                        <?php } else { ?>
                                    <a href="javascript:contestapp.likecomment(<?php echo $c['data_id']; ?>)">
                                        STEM
                                    </a>
                        <?php } ?>
                    <?php } else { ?>
                        <a href="javascript:contestapp.unlikecomment(<?php echo $c['data_id']; ?>)">
                            STEM
                        </a>
                    <?php } ?>                                       
                </div>
                -->
            </td>
        <?php } ?>
    </tr>
    <?php } ?>        
</table>


<?php if(@$view->app_data) {?>
<script type="text/javascript">
//    facebooktab.showLikeLightbox(<?php echo $view->app_data;?>);
</script>
<?php } ?>

<script type="text/javascript">
    contestapp.images.unlike = "<?php echo $this->config['template_url'];?>assets/img/810/voted.png";
</script>